package org.malred.hotelsystem.utils;

import android.util.Log;
import android.widget.EditText;
import android.widget.RadioButton;

public class ToolsUtil {
    private static final String TAG = "ToolsUtil";

    /**
     * 获取输入框的文本
     *
     * @param et
     * @return
     */
    public static String editTxtToStr(EditText et) {
        Log.i(TAG, "editTxtToStr: " + et.getText());
        return et.getText().toString().trim();
    }

    public static boolean isEmpty(String str) {
        return str.length() == 0;
    }

    public static boolean isCheck(RadioButton rb){
        return rb.isChecked();
    }
}

